package com.liao.service;

import com.liao.bean.Role;
import com.liao.bean.result.PageResult;

public interface RoleService {
    /**
     * 分页查询菜单列表
     * @param currentPage
     * @param pageSize
     * @param roleName
     * @return
     * @throws Exception
     */
    PageResult<Role> queryRoleListByPage(Integer currentPage, Integer pageSize, String roleName) throws Exception;

    /**
     * 添加角色
     * @param role
     */
    void addRole(Role role) throws Exception;

    /**
     * 根据id查询角色
     * @param roleId
     * @return
     * @throws Exception
     */
    Role queryRoleById(String roleId) throws Exception;

    /**
     * 根据id删除角色
     * @param roleId
     * @throws Exception
     */
    void deleteRole(String roleId) throws Exception;

    /**
     * 修改角色信息
     * @param oldRoleId
     * @param roleId
     * @param roleName
     * @param roleDesc
     * @throws Exception
     */
    void editRole(String oldRoleId, String roleId, String roleName, String roleDesc) throws Exception;
}
